package cn.yzgy.yzgyoa.common.service.impl;

import cn.yzgy.yzgyoa.common.entity.SysParams;
import cn.yzgy.yzgyoa.common.mapper.SysParamsMapper;
import cn.yzgy.yzgyoa.common.service.ISysParamsService;
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import org.springframework.stereotype.Service;

/**
 * <p>
 * 参数表
 服务实现类
 * </p>
 *
 * @author Yqsen
 * @since 2020-11-09
 */
@Service
public class SysParamsServiceImpl extends ServiceImpl<SysParamsMapper, SysParams> implements ISysParamsService {

    @Override
    public SysParams getSysParams(String keyName) {
        return baseMapper.selectOne(new QueryWrapper<SysParams>().lambda().eq(SysParams::getKeyName,keyName));
    }
}
